The present invention is related to a calibration device for an oscillator and a method thereof, and more particularly to a calibration device for calibrating a characteristic curve of the oscillator and a method thereof.
In a wireless communication system, an oscillator is used to generate an oscillating clock signal having a required oscillating frequency. Normally, the oscillating frequency range of an oscillator can be evaluated by two aspects: the dynamic range (DR), and the static range (SR). The ideal dynamic range and the ideal static range of an oscillator are illustrated in FIG. 1, which is a diagram illustrating a plurality of characteristic curves of an ideal oscillator. The oscillator can be controlled to generate different oscillating frequencies depending on the AFC (automatic frequency control) codes (e.g. 0˜8191) and the CapID codes (e.g. 0˜127). More specifically, the middle AFC code is used to determine the static range of the oscillator, and each AFC code is used to control the oscillator to generate the required oscillating frequency. Ideally, for each CapID code, the relation between the AFC code and the oscillating frequency is linear, i.e., the plurality of straight lines as shown in FIG. 1. In practice, however, the relation between the AFC code and the oscillating frequency of the oscillator is not linear, such that the line representing the transfer function between the AFC code and the oscillating frequency will be a curve instead of a straight line as shown in FIG. 1. Consequently, the wireless communication system may not have enough margins to track the temperature variation and crystal aging, and may not have enough margins for initial crystal offset and static error during the manufacturing process (e.g. the soldering process). Moreover, using the conventional off-chip instrument to test the SR and DR of an oscillator is time consuming and involves extra costs. Therefore, providing an effective and low-cost way to test and calibrate the SR and DR of an oscillator is an urgent problem in this field.